!function (modules) {
    // The module cache
    var installedModules = {};

    // The require function
    function __webpack_require__(moduleId) {
        // Check if module is in cache
        if (installedModules[moduleId])
            return installedModules[moduleId].exports;

        // Create a new module (and put it into the cache)
        var module = installedModules[moduleId] = {
            i: moduleId,
            l: !1,
            exports: {}
        };

        // Execute the module function
        return modules[moduleId].call(module.exports, module, module.exports, __webpack_require__),
            // Flag the module as loaded
            module.l = !0,
            // Return the exports of the module
            module.exports
    }

    // expose the modules object (__webpack_modules__)
    __webpack_require__.m = modules,

        // expose the module cache
        __webpack_require__.c = installedModules,

        // define getter function for harmony exports
        __webpack_require__.d = function (exports, name, getter) {
            __webpack_require__.hasOwnProperty(exports, name) || Object.defineProperty(exports, name, {
                enumerable: !0,
                get: getter
            })
        }
        ,

        // define __esModule on exports
        __webpack_require__.r = function (target) {
            "undefined" != typeof Symbol && Symbol.toStringTag && Object.defineProperty(target, Symbol.toStringTag, {
                value: "Module"
            }),
                Object.defineProperty(target, "__esModule", {
                    value: !0
                })
        }
        ,
        // create a fake namespace object
        // mode & 1: value is a module id, require it
        // mode & 2: merge all properties of value into the ns
        // mode & 4: return value when already ns object
        // mode & 8|1: behave like require
        __webpack_require__.t = function (value, mode) {
            if (1 & mode && (value = __webpack_require__(value)),
                8 & mode)
                return value;
            if (4 & mode && "object" == typeof value && value && value.__esModule)
                return value;
            var ns = Object.create(null);
            if (__webpack_require__.r(ns),
                Object.defineProperty(ns, "default", {
                    enumerable: !0,
                    value: value
                }),
                2 & mode && "string" != typeof value)
                for (var o in value)
                    __webpack_require__.d(ns, o, function (e) {
                        return value[e]
                    }
                        .bind(null, o));
            return ns
        }
        ,
        // getDefaultExport function for compatibility with non-harmony modules
        __webpack_require__.n = function (module) {
            var getter = module && module.__esModule ? function () {
                return module.default
            }
                : function () {
                    return module
                }
                ;
            return __webpack_require__.d(getter, "a", getter),
                getter
        }
        ,
        // Object.prototype.hasOwnProperty.call
        __webpack_require__.hasOwnProperty = function (target, propName) {
            return Object.prototype.hasOwnProperty.call(target, propName)
        }
        ,
        // __webpack_public_path__
        __webpack_require__.p = "",
        // Load entry module and return exports
        __webpack_require__(__webpack_require__.s = 4),

        window.installedModules = installedModules;
}([function f0(t, e, n) {
    "use strict";
    e.a = function (t) {
        var e = this.constructor;
        return this.then(function (n) {
            return e.resolve(t()).then(function () {
                return n
            })
        }, function (n) {
            return e.resolve(t()).then(function () {
                return e.reject(n)
            })
        })
    }
}
    , function f1(t, e) {
        var n;
        n = function () {
            return this
        }();
        try {
            n = n || new Function("return this")()
        } catch (t) {
            "object" == typeof window && (n = window)
        }
        t.exports = n
    }
    , function f2(t, e, n) {
        "use strict";
        Object.defineProperty(e, "__esModule", {
            value: !0
        });
        var i = function (t) {
            return t && "object" == typeof t
        };
        e.mergeDeep = function () {
            for (var t = [], n = 0; n < arguments.length; n++)
                t[n] = arguments[n];
            var o = {};
            return t.forEach(function (t) {
                Object.keys(t).forEach(function (n) {
                    var r = o[n]
                        , s = t[n];
                    void 0 !== s && (Array.isArray(r) || Array.isArray(s) ? o[n] = s : i(r) && i(s) ? o[n] = e.mergeDeep(r, s) : o[n] = s)
                })
            }),
                o
        }
            ,
            e.getFrameDocument = function (t) {
                return t.contentWindow && t.contentWindow.document || t.contentDocument
            }
            ,
            e.resolveTargetElement = function (t) {
                return t instanceof Element ? t : "string" == typeof t ? document.getElementById(t) : document.getElementsByTagName("body")[0]
            }
            ,
            e.createScript = function (t, e) {
                var n = t.createElement("script");
                return n.type = "text/javascript",
                    n.charset = "utf-8",
                    e && (n.src = e),
                    n
            }
            ,
            e.createLink = function (t, e) {
                var n = t.createElement("link");
                return n.type = "text/css",
                    n.rel = "stylesheet",
                    n.charset = "utf-8",
                    n.href = e,
                    n
            }
            ,
            e.request = function (t) {
                var e = new XMLHttpRequest;
                return new Promise(function (n, i) {
                    e.onreadystatechange = function () {
                        4 === e.readyState && (e.status >= 200 && e.status < 300 ? n(e.response) : i(new Error("Request failed with status " + e.status)))
                    }
                        ,
                        e.open("GET", t, !0),
                        e.send()
                }
                )
            }
            ,
            e.post = function (t, d) {
                var e = new XMLHttpRequest;
                return new Promise(function (n, i) {
                    e.onreadystatechange = function () {
                        4 === e.readyState && (e.status >= 200 && e.status < 300 ? n(e.response) : i(new Error("Request failed with status " + e.status)))
                    }
                        ,

                        e.open("POST", t, !0),
                        e.setRequestHeader('content-type', 'application/json'),
                        e.send(JSON.stringify(d))
                }
                )
            }
            ,
            e.parseJSON = function (t) {
                if (JSON.parse)
                    return JSON.parse(t);
                if (JSON.decode)
                    return JSON.decode(t);
                throw new Error("Unable to parse json.")
            }
    }
    , function f3(t, e, n) {
        "use strict";
        (function (t) {
            var i = n(0)
                , o = setTimeout;
            function r(t) {
                return Boolean(t && void 0 !== t.length)
            }
            function s() { }
            function a(t) {
                if (!(this instanceof a))
                    throw new TypeError("Promises must be constructed via new");
                if ("function" != typeof t)
                    throw new TypeError("not a function");
                this._state = 0,
                    this._handled = !1,
                    this._value = void 0,
                    this._deferreds = [],
                    d(t, this)
            }
            function u(t, e) {
                for (; 3 === t._state;)
                    t = t._value;
                0 !== t._state ? (t._handled = !0,
                    a._immediateFn(function () {
                        var n = 1 === t._state ? e.onFulfilled : e.onRejected;
                        if (null !== n) {
                            var i;
                            try {
                                i = n(t._value)
                            } catch (t) {
                                return void l(e.promise, t)
                            }
                            c(e.promise, i)
                        } else
                            (1 === t._state ? c : l)(e.promise, t._value)
                    })) : t._deferreds.push(e)
            }
            function c(t, e) {
                try {
                    if (e === t)
                        throw new TypeError("A promise cannot be resolved with itself.");
                    if (e && ("object" == typeof e || "function" == typeof e)) {
                        var n = e.then;
                        if (e instanceof a)
                            return t._state = 3,
                                t._value = e,
                                void p(t);
                        if ("function" == typeof n)
                            return void d((i = n,
                                o = e,
                                function () {
                                    i.apply(o, arguments)
                                }
                            ), t)
                    }
                    t._state = 1,
                        t._value = e,
                        p(t)
                } catch (e) {
                    l(t, e)
                }
                var i, o
            }
            function l(t, e) {
                t._state = 2,
                    t._value = e,
                    p(t)
            }
            function p(t) {
                2 === t._state && 0 === t._deferreds.length && a._immediateFn(function () {
                    t._handled || a._unhandledRejectionFn(t._value)
                });
                for (var e = 0, n = t._deferreds.length; e < n; e++)
                    u(t, t._deferreds[e]);
                t._deferreds = null
            }
            function f(t, e, n) {
                this.onFulfilled = "function" == typeof t ? t : null,
                    this.onRejected = "function" == typeof e ? e : null,
                    this.promise = n
            }
            function d(t, e) {
                var n = !1;
                try {
                    t(function (t) {
                        n || (n = !0,
                            c(e, t))
                    }, function (t) {
                        n || (n = !0,
                            l(e, t))
                    })
                } catch (t) {
                    if (n)
                        return;
                    n = !0,
                        l(e, t)
                }
            }
            a.prototype.catch = function (t) {
                return this.then(null, t)
            }
                ,
                a.prototype.then = function (t, e) {
                    var n = new this.constructor(s);
                    return u(this, new f(t, e, n)),
                        n
                }
                ,
                a.prototype.finally = i.a,
                a.all = function (t) {
                    return new a(function (e, n) {
                        if (!r(t))
                            return n(new TypeError("Promise.all accepts an array"));
                        var i = Array.prototype.slice.call(t);
                        if (0 === i.length)
                            return e([]);
                        var o = i.length;
                        function s(t, r) {
                            try {
                                if (r && ("object" == typeof r || "function" == typeof r)) {
                                    var a = r.then;
                                    if ("function" == typeof a)
                                        return void a.call(r, function (e) {
                                            s(t, e)
                                        }, n)
                                }
                                i[t] = r,
                                    0 == --o && e(i)
                            } catch (t) {
                                n(t)
                            }
                        }
                        for (var a = 0; a < i.length; a++)
                            s(a, i[a])
                    }
                    )
                }
                ,
                a.resolve = function (t) {
                    return t && "object" == typeof t && t.constructor === a ? t : new a(function (e) {
                        e(t)
                    }
                    )
                }
                ,
                a.reject = function (t) {
                    return new a(function (e, n) {
                        n(t)
                    }
                    )
                }
                ,
                a.race = function (t) {
                    return new a(function (e, n) {
                        if (!r(t))
                            return n(new TypeError("Promise.race accepts an array"));
                        for (var i = 0, o = t.length; i < o; i++)
                            a.resolve(t[i]).then(e, n)
                    }
                    )
                }
                ,
                a._immediateFn = "function" == typeof t && function (e) {
                    t(e)
                }
                || function (t) {
                    o(t, 0)
                }
                ,
                a._unhandledRejectionFn = function (t) {
                    "undefined" != typeof console && console && console.warn("Possible Unhandled Promise Rejection:", t)
                }
                ,
                e.a = a
        }
        ).call(this, n(6).setImmediate)
    }
    , function f4(t, e, n) {
        "use strict";
        Object.defineProperty(e, "__esModule", {
            value: !0
        }),
            n(5);
        var i = n(9)
            , o = n(11);
        if (window.smartsupp || (window.smartsupp = function () {
            window.smartsupp._.push(arguments)
        }
            ,
            window.smartsupp._ = []),
            !window.SMARTSUPP_LOADED) {
            window.SMARTSUPP_LOADED = !0,
                window.$smartsupp = new i.SmartsuppLoader({
                    widgetVersion: 1,
                    bootstrapUrl: '//' + location.host,
                    filesUrl: "https://files.smartsuppcdn.com",
                    widgetV1Url: "https://widget-v1.smartsuppcdn.com",
                    widgetV2Url: '//' + location.host,
                    zIndex: 1e7,
                    position: "auto",
                    orientation: "right",
                    autoInlineMode: !0
                }),
                window.smartsupp.chats = window.$smartsupp.widgets;
            for (var function_idx = 0, functions = ["create", "createWidget", "getChat", "getWidget", "setDefaults"]; function_idx < functions.length; function_idx++) {
                var funcName = functions[function_idx];
                window.smartsupp[funcName] = window.$smartsupp[funcName].bind(window.$smartsupp)
            }
            !1 !== window.SMARTSUPP_AUTOCREATE && o(function () {
                window.smartsupp("html:apply", document),
                    window.$smartsupp.createWidget("chat", window._smartsupp, window.smartsupp._).then(function (t) {
                        return t.initPlugins(),
                            t.render()
                    }).catch(function (t) {
                        console.warn(t)
                    })
            })
        }
    }
    , function f5(t, e, n) {
        "use strict";
        n.r(e),
            function (t) {
                var e = n(3)
                    , i = n(0)
                    , o = function () {
                        if ("undefined" != typeof self)
                            return self;
                        if ("undefined" != typeof window)
                            return window;
                        if (void 0 !== t)
                            return t;
                        throw new Error("unable to locate global object")
                    }();
                "Promise" in o ? o.Promise.prototype.finally || (o.Promise.prototype.finally = i.a) : o.Promise = e.a
            }
                .call(this, n(1))
    }
    , function f6(t, e, n) {
        (function (t) {
            var i = void 0 !== t && t || "undefined" != typeof self && self || window
                , o = Function.prototype.apply;
            function r(t, e) {
                this._id = t,
                    this._clearFn = e
            }
            e.setTimeout = function () {
                return new r(o.call(setTimeout, i, arguments), clearTimeout)
            }
                ,
                e.setInterval = function () {
                    return new r(o.call(setInterval, i, arguments), clearInterval)
                }
                ,
                e.clearTimeout = e.clearInterval = function (t) {
                    t && t.close()
                }
                ,
                r.prototype.unref = r.prototype.ref = function () { }
                ,
                r.prototype.close = function () {
                    this._clearFn.call(i, this._id)
                }
                ,
                e.enroll = function (t, e) {
                    clearTimeout(t._idleTimeoutId),
                        t._idleTimeout = e
                }
                ,
                e.unenroll = function (t) {
                    clearTimeout(t._idleTimeoutId),
                        t._idleTimeout = -1
                }
                ,
                e._unrefActive = e.active = function (t) {
                    clearTimeout(t._idleTimeoutId);
                    var e = t._idleTimeout;
                    e >= 0 && (t._idleTimeoutId = setTimeout(function () {
                        t._onTimeout && t._onTimeout()
                    }, e))
                }
                ,
                n(7),
                e.setImmediate = "undefined" != typeof self && self.setImmediate || void 0 !== t && t.setImmediate || this && this.setImmediate,
                e.clearImmediate = "undefined" != typeof self && self.clearImmediate || void 0 !== t && t.clearImmediate || this && this.clearImmediate
        }
        ).call(this, n(1))
    }
    , function f7(t, e, n) {
        (function (t, e) {
            !function (t, n) {
                "use strict";
                if (!t.setImmediate) {
                    var i, o, r, s, a, u = 1, c = {}, l = !1, p = t.document, f = Object.getPrototypeOf && Object.getPrototypeOf(t);
                    f = f && f.setTimeout ? f : t,
                        "[object process]" === {}.toString.call(t.process) ? i = function (t) {
                            e.nextTick(function () {
                                h(t)
                            })
                        }
                            : !function () {
                                if (t.postMessage && !t.importScripts) {
                                    var e = !0
                                        , n = t.onmessage;
                                    return t.onmessage = function () {
                                        e = !1
                                    }
                                        ,
                                        t.postMessage("", "*"),
                                        t.onmessage = n,
                                        e
                                }
                            }() ? t.MessageChannel ? ((r = new MessageChannel).port1.onmessage = function (t) {
                                h(t.data)
                            }
                                ,
                                i = function (t) {
                                    r.port2.postMessage(t)
                                }
                            ) : p && "onreadystatechange" in p.createElement("script") ? (o = p.documentElement,
                                i = function (t) {
                                    var e = p.createElement("script");
                                    e.onreadystatechange = function () {
                                        h(t),
                                            e.onreadystatechange = null,
                                            o.removeChild(e),
                                            e = null
                                    }
                                        ,
                                        o.appendChild(e)
                                }
                            ) : i = function (t) {
                                setTimeout(h, 0, t)
                            }
                                : (s = "setImmediate$" + Math.random() + "$",
                                    a = function (e) {
                                        e.source === t && "string" == typeof e.data && 0 === e.data.indexOf(s) && h(+e.data.slice(s.length))
                                    }
                                    ,
                                    t.addEventListener ? t.addEventListener("message", a, !1) : t.attachEvent("onmessage", a),
                                    i = function (e) {
                                        t.postMessage(s + e, "*")
                                    }
                                ),
                        f.setImmediate = function (t) {
                            "function" != typeof t && (t = new Function("" + t));
                            for (var e = new Array(arguments.length - 1), n = 0; n < e.length; n++)
                                e[n] = arguments[n + 1];
                            var o = {
                                callback: t,
                                args: e
                            };
                            return c[u] = o,
                                i(u),
                                u++
                        }
                        ,
                        f.clearImmediate = d
                }
                function d(t) {
                    delete c[t]
                }
                function h(t) {
                    if (l)
                        setTimeout(h, 0, t);
                    else {
                        var e = c[t];
                        if (e) {
                            l = !0;
                            try {
                                !function (t) {
                                    var e = t.callback
                                        , i = t.args;
                                    switch (i.length) {
                                        case 0:
                                            e();
                                            break;
                                        case 1:
                                            e(i[0]);
                                            break;
                                        case 2:
                                            e(i[0], i[1]);
                                            break;
                                        case 3:
                                            e(i[0], i[1], i[2]);
                                            break;
                                        default:
                                            e.apply(n, i)
                                    }
                                }(e)
                            } finally {
                                d(t),
                                    l = !1
                            }
                        }
                    }
                }
            }("undefined" == typeof self ? void 0 === t ? this : t : self)
        }
        ).call(this, n(1), n(8))
    }
    , function f8(t, e) {
        var n, i, o = t.exports = {};
        function r() {
            throw new Error("setTimeout has not been defined")
        }
        function s() {
            throw new Error("clearTimeout has not been defined")
        }
        function a(t) {
            if (n === setTimeout)
                return setTimeout(t, 0);
            if ((n === r || !n) && setTimeout)
                return n = setTimeout,
                    setTimeout(t, 0);
            try {
                return n(t, 0)
            } catch (e) {
                try {
                    return n.call(null, t, 0)
                } catch (e) {
                    return n.call(this, t, 0)
                }
            }
        }
        !function () {
            try {
                n = "function" == typeof setTimeout ? setTimeout : r
            } catch (t) {
                n = r
            }
            try {
                i = "function" == typeof clearTimeout ? clearTimeout : s
            } catch (t) {
                i = s
            }
        }();
        var u, c = [], l = !1, p = -1;
        function f() {
            l && u && (l = !1,
                u.length ? c = u.concat(c) : p = -1,
                c.length && d())
        }
        function d() {
            if (!l) {
                var t = a(f);
                l = !0;
                for (var e = c.length; e;) {
                    for (u = c,
                        c = []; ++p < e;)
                        u && u[p].run();
                    p = -1,
                        e = c.length
                }
                u = null,
                    l = !1,
                    function (t) {
                        if (i === clearTimeout)
                            return clearTimeout(t);
                        if ((i === s || !i) && clearTimeout)
                            return i = clearTimeout,
                                clearTimeout(t);
                        try {
                            i(t)
                        } catch (e) {
                            try {
                                return i.call(null, t)
                            } catch (e) {
                                return i.call(this, t)
                            }
                        }
                    }(t)
            }
        }
        function h(t, e) {
            this.fun = t,
                this.array = e
        }
        function m() { }
        o.nextTick = function (t) {
            var e = new Array(arguments.length - 1);
            if (arguments.length > 1)
                for (var n = 1; n < arguments.length; n++)
                    e[n - 1] = arguments[n];
            c.push(new h(t, e)),
                1 !== c.length || l || a(d)
        }
            ,
            h.prototype.run = function () {
                this.fun.apply(null, this.array)
            }
            ,
            o.title = "browser",
            o.browser = !0,
            o.env = {},
            o.argv = [],
            o.version = "",
            o.versions = {},
            o.on = m,
            o.addListener = m,
            o.once = m,
            o.off = m,
            o.removeListener = m,
            o.removeAllListeners = m,
            o.emit = m,
            o.prependListener = m,
            o.prependOnceListener = m,
            o.listeners = function (t) {
                return []
            }
            ,
            o.binding = function (t) {
                throw new Error("process.binding is not supported")
            }
            ,
            o.cwd = function () {
                return "/"
            }
            ,
            o.chdir = function (t) {
                throw new Error("process.chdir is not supported")
            }
            ,
            o.umask = function () {
                return 0
            }
    }
    , function f9(t, e, n) {
        "use strict";
        Object.defineProperty(e, "__esModule", {
            value: !0
        });
        var i = n(2)
            , o = n(10)
            , r = function () {
                function t(t) {
                    this.options = t,
                        this.widgets = {}
                }
                return t.prototype.setDefaults = function (t) {
                    return this.options = i.mergeDeep(this.options, t),
                        this
                }
                    ,
                    t.prototype.getChat = function (t) {
                        return this.widgets[t]
                    }
                    ,
                    t.prototype.getWidget = function (t) {
                        return this.widgets[t]
                    }
                    ,
                    t.prototype.create = function (t, e, n, r) {
                        var a = i.mergeDeep(this.options, e);
                        s(a);
                        var u = this.widgets[t] = new o.SmartsuppWidget(t, a, n);
                        return u._initPromise = i.request(a.bootstrapUrl + "/widget/" + a.key + ".json").then(function (t) {
                            var n = i.parseJSON(t);
                            delete e.features,
                                u.init(i.mergeDeep(n, n.config, e)),
                                r && r(void 0, u),
                                u.options.renderTo && u.render(u.options.renderTo)
                        }).catch(function (t) {
                            r && r(t)
                        }),
                            u
                    }
                    ,
                    t.prototype.createWidget = function (t, e, n) {
                        var r = this
                            , a = i.mergeDeep(this.options, e);
                        return s(a),
                            i.request(a.bootstrapUrl + "/widget/" + a.key + ".json").then(function (s) {
                                var u = i.parseJSON(s)
                                    , c = r.widgets[t] = new o.SmartsuppWidget(t, a, n);
                                return delete e.features,
                                    c.init(i.mergeDeep(u, u.config, e)),
                                    c
                            })
                    }
                    ,
                    t
            }();
        e.SmartsuppLoader = r;
        var s = function (t) {
            if (!t.bootstrapUrl)
                throw new Error("Missing option bootstrapUrl");
            if (!t.key)
                throw new Error("Missing option key")
        }
    }
    , function f10(t, e, n) {
        "use strict";
        var i = this && this.__assign || function () {
            return (i = Object.assign || function (t) {
                for (var e, n = 1, i = arguments.length; n < i; n++)
                    for (var o in e = arguments[n])
                        Object.prototype.hasOwnProperty.call(e, o) && (t[o] = e[o]);
                return t
            }
            ).apply(this, arguments)
        }
            , o = this && this.__awaiter || function (t, e, n, i) {
                return new (n || (n = Promise))(function (o, r) {
                    function s(t) {
                        try {
                            u(i.next(t))
                        } catch (t) {
                            r(t)
                        }
                    }
                    function a(t) {
                        try {
                            u(i.throw(t))
                        } catch (t) {
                            r(t)
                        }
                    }
                    function u(t) {
                        t.done ? o(t.value) : new n(function (e) {
                            e(t.value)
                        }
                        ).then(s, a)
                    }
                    u((i = i.apply(t, e || [])).next())
                }
                )
            }
            , r = this && this.__generator || function (t, e) {
                var n, i, o, r, s = {
                    label: 0,
                    sent: function () {
                        if (1 & o[0])
                            throw o[1];
                        return o[1]
                    },
                    trys: [],
                    ops: []
                };
                return r = {
                    next: a(0),
                    throw: a(1),
                    return: a(2)
                },
                    "function" == typeof Symbol && (r[Symbol.iterator] = function () {
                        return this
                    }
                    ),
                    r;
                function a(r) {
                    return function (a) {
                        return function (r) {
                            if (n)
                                throw new TypeError("Generator is already executing.");
                            for (; s;)
                                try {
                                    if (n = 1,
                                        i && (o = 2 & r[0] ? i.return : r[0] ? i.throw || ((o = i.return) && o.call(i),
                                            0) : i.next) && !(o = o.call(i, r[1])).done)
                                        return o;
                                    switch (i = 0,
                                    o && (r = [2 & r[0], o.value]),
                                    r[0]) {
                                        case 0:
                                        case 1:
                                            o = r;
                                            break;
                                        case 4:
                                            return s.label++,
                                            {
                                                value: r[1],
                                                done: !1
                                            };
                                        case 5:
                                            s.label++,
                                                i = r[1],
                                                r = [0];
                                            continue;
                                        case 7:
                                            r = s.ops.pop(),
                                                s.trys.pop();
                                            continue;
                                        default:
                                            if (!(o = (o = s.trys).length > 0 && o[o.length - 1]) && (6 === r[0] || 2 === r[0])) {
                                                s = 0;
                                                continue
                                            }
                                            if (3 === r[0] && (!o || r[1] > o[0] && r[1] < o[3])) {
                                                s.label = r[1];
                                                break
                                            }
                                            if (6 === r[0] && s.label < o[1]) {
                                                s.label = o[1],
                                                    o = r;
                                                break
                                            }
                                            if (o && s.label < o[2]) {
                                                s.label = o[2],
                                                    s.ops.push(r);
                                                break
                                            }
                                            o[2] && s.ops.pop(),
                                                s.trys.pop();
                                            continue
                                    }
                                    r = e.call(t, s)
                                } catch (t) {
                                    r = [6, t],
                                        i = 0
                                } finally {
                                    n = o = 0
                                }
                            if (5 & r[0])
                                throw r[1];
                            return {
                                value: r[0] ? r[1] : void 0,
                                done: !0
                            }
                        }([r, a])
                    }
                }
            }
            ;
        Object.defineProperty(e, "__esModule", {
            value: !0
        });
        var s = n(2)
            , a = window
            , u = function () {
                function t(t, e, n) {
                    if (this.id = t,
                        this.options = e,
                        this._pushApi = n,
                        this.rendered = !1,
                        this.api = null,
                        this.el = null,
                        this.frame = null,
                        this.version = 2,
                        this.smartlook = void 0,
                        this.initialized = !1,
                        !e.bootstrapUrl)
                        throw new Error("Missing option bootstrapUrl");
                    if (!e.key)
                        throw new Error("Missing option key")
                }
                return t.prototype.setOptions = function (t) {
                    return this.options = s.mergeDeep(this.options, t),
                        this
                }
                    ,
                    t.prototype.init = function (t) {
                        var e = this;
                        this.setOptions(t),
                            this.initialized = !0,
                            "auto" === this.options.position && (this.options.position = this.options.renderTo ? "relative" : "fixed"),
                            this._pushApi && this._pushApi.forEach(function (t) {
                                "recording:disable" === t[0] ? e.options.recordingDisable = !0 : "recording:off" === t[0] && (e.options.recordingOff = !0)
                            })
                    }
                    ,
                    t.prototype.createContainer = function () {
                        var t = document.createElement("div");
                        if (t.id = this.id + "-application",
                            t.setAttribute("style", "background: transparent; overflow: hidden; display: block; margin: 0; padding: 0; bottom: 0; transition: none;"),
                            t.style.zIndex = this.options.zIndex ? "" + (this.options.zIndex + 1) : null,
                            "fixed" === this.options.position) {
                            var e = this.options.offsetX ? this.options.offsetX + "px" : "1px";
                            t.style.position = "fixed",
                                t.style.bottom = "1px",
                                t.style.width = "1px",
                                t.style.height = "1px",
                                this.options.alignX ? "right" === this.options.alignX ? t.style.right = e : t.style.left = e : this.options.orientation && ("right" === this.options.orientation ? t.style.right = e : t.style.left = e)
                        }
                        return t
                    }
                    ,
                    t.prototype.createFrame = function () {
                        var t = document.createElement("iframe");
                        return t.id = this.id + "-application-iframe",
                            t.setAttribute("title", "Smartsupp"),
                            t.setAttribute("aria-hidden", "true"),
                            t.setAttribute("style", "background: transparent; overflow: hidden; position: relative; width: 100%; height: 100%; margin: 0px; border: none; min-width: inherit; max-width: inherit; min-height: inherit; max-height: inherit; transition: none;"),
                            t.style.zIndex = this.options.zIndex ? "" + (this.options.zIndex + 1) : null,
                            t
                    }
                    ,
                    t.prototype.render = function (t) {
                        return o(this, void 0, void 0, function () {
                            var e;
                            return r(this, function (n) {
                                switch (n.label) {
                                    case 0:
                                        return document.getElementById(this.id + "-application") ? [2] : this._initPromise ? [4, this._initPromise] : [3, 2];
                                    case 1:
                                        n.sent(),
                                            n.label = 2;
                                    case 2:
                                        if (!this.initialized)
                                            throw new Error("failed to initialize widget");
                                        if (!t && this.options.renderTo && (t = this.options.renderTo),
                                            t && (this.options.zIndex = null),
                                            !(e = s.resolveTargetElement(t)))
                                            throw new Error("target element not found");
                                        return this.el = this.createContainer(),
                                            [4, this.renderFrame(this.el, e)];
                                    case 3:
                                        return n.sent(),
                                            this.rendered = !0,
                                            [2]
                                }
                            })
                        })
                    }
                    ,
                    t.prototype.renderFrame = function (t, e) {
                        var n = this.frame = this.createFrame();
                        return t.appendChild(n),
                            e.childNodes.length > 0 ? e.insertBefore(t, e.childNodes[0]) : e.appendChild(t),
                            1 === this.options.widgetVersion ? this.renderFrameV1(n) : this.renderFrameV2(n)
                    }
                    ,
                    t.prototype.renderFrameV1 = function (t) {
                        return o(this, void 0, void 0, function () {
                            var e, n, i, o, a, u = this;
                            return r(this, function (r) {
                                switch (r.label) {
                                    case 0:
                                        return [4, s.request(this.getBaseUrl() + "/metadata.json").then(function (t) {
                                            return s.parseJSON(t)
                                        })];
                                    case 1:
                                        return e = r.sent(),
                                            (n = s.getFrameDocument(t)).open(),
                                            n.write('<!DOCTYPE html>\n\t\t<html>\n\t\t\t<head>\n\t\t\t\t<title>Smartsupp Chat</title>\n\t\t\t\t<meta http-equiv="Content-Type" content="text/html; charset=utf-8">\n\t\t\t</head>\n\t\t\t<body id="body" data-smartsupp-id="' + this.id + '"></body>\n\t\t</html>'),
                                            i = n.getElementsByTagName("head")[0],
                                            e.styles.forEach(function (t) {
                                                var e = s.createLink(n, u.getBaseUrl() + t);
                                                i.appendChild(e)
                                            }),
                                            this.options.disableInternalApi || !this.options.hasInternalApi ? [3, 3] : [4, s.request(this.getInternalApiUrl())];
                                    case 2:
                                        o = r.sent(),
                                            (a = s.createScript(n)).text = "var smartsupp = window.parent.smartsupp;\n var _smartsupp = _smartsupp || {}; \n\n" + o,
                                            i.appendChild(a),
                                            r.label = 3;
                                    case 3:
                                        return e.scripts.forEach(function (t) {
                                            var e = s.createScript(n, u.getBaseUrl() + t);
                                            i.appendChild(e)
                                        }),
                                            n.close(),
                                            [2]
                                }
                            })
                        })
                    }
                    ,
                    t.prototype.renderFrameV2 = function (t) {
                        return o(this, void 0, void 0, function () {
                            var e, n, i, o = this;
                            return r(this, function (r) {
                                switch (r.label) {
                                    case 0:
                                        return [4, s.request(this.getBaseUrl() + "/asset-manifest.json").then(function (t) {
                                            return s.parseJSON(t)
                                        })];
                                    case 1:
                                        return e = r.sent(),
                                            (n = s.getFrameDocument(t)).open(),
                                            n.write('<!DOCTYPE html>\n\t\t<html lang="en">\n\t\t\t<head>\n\t\t\t\t<title>Smartsupp Chat</title>\n\t\t\t\t<base href="' + this.getBaseUrl() + '" target="_blank">\n\t\t\t\t<meta charset="utf-8" />\n\t\t\t\t<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0" />\n\t\t\t</head>\n\t\t\t<body id="body" data-smartsupp-id="' + this.id + '">\n\t\t\t\t<div id="root" />\n\t\t\t</body>\n\t\t</html>'),
                                            i = n.getElementsByTagName("head")[0],
                                            e.entrypoints.forEach(function (t) {
                                                var e = s.createScript(n, o.getBaseUrl() + "/" + t);
                                                i.appendChild(e)
                                            }),
                                            n.close(),
                                            [2]
                                }
                            })
                        })
                    }
                    ,
                    t.prototype.destroy = function () {
                        this.el && this.el.parentNode && (this.el.parentNode.removeChild(this.el),
                            delete this.el)
                    }
                    ,
                    t.prototype.getOption = function (t, e) {
                        return void 0 !== this.options[t] ? this.options[t] : e
                    }
                    ,
                    t.prototype.getBaseUrl = function () {
                        return 2 === this.options.widgetVersion ? this.options.widgetV2Url : this.options.widgetV1Url
                    }
                    ,
                    t.prototype.getInternalApiUrl = function () {
                        return this.options.bootstrapUrl + "/widget/" + this.options.key + "/code.js"
                    }
                    ,
                    t.prototype.installApi = function (t) {
                        if (this.api = t,
                            a.smartsupp.api = t,
                            this._pushApi && (this._pushApi.forEach(function (e) {
                                var n = Array.prototype.slice.call(e, 0);
                                try {
                                    t.execute(n)
                                } catch (t) {
                                    console.log(t)
                                }
                            }),
                                this._pushApi.push = function (e) {
                                    var n = Array.prototype.slice.call(e, 0);
                                    try {
                                        t.execute(n)
                                    } catch (t) {
                                        console.log(t)
                                    }
                                }
                            ),
                            this.options.onStartup)
                            try {
                                this.options.onStartup(t)
                            } catch (t) {
                                console.log(t)
                            }
                    }
                    ,
                    t.prototype.initPlugins = function () {
                        this.options.smartlook && this.isAllowedSmartlook() && this.initSmartlook(i({}, this.options.smartlook, {
                            cookieDomain: this.options.cookieDomain,
                            cookiePath: this.options.cookiePath
                        }))
                    }
                    ,
                    t.prototype.isAllowedSmartlook = function () {
                        return !a.smartlook && (!(!this.options.smartlook || !this.options.smartlook.enabled) && !this.options.recordingOff)
                    }
                    ,
                    t.prototype.initSmartlook = function (t) {
                        this.smartlook = a.smartlook = function () {
                            a.smartlook.api.push(arguments)
                        }
                            ,
                            a.smartlook.api = [];
                        var e = window.document.getElementsByTagName("head")[0]
                            , n = window.document.createElement("script");
                        n.async = !0,
                            n.type = "text/javascript",
                            n.charset = "utf-8",
                            n.crossOrigin = "anonymous",
                            n.src = t.scriptUrl,
                            e.appendChild(n),
                            this.smartlook("init", t.key, {
                                host: t.serverHost,
                                cookieDomain: t.cookieDomain,
                                cookiePath: t.cookiePath
                            }),
                            this.smartlook("expertForms"),
                            this.smartlook("expertAPI"),
                            this.options.recordingDisable && this.smartlook("disable")
                    }
                    ,
                    t
            }();
        e.SmartsuppWidget = u
    }
    , function f11(t, e, n) {
        /*!
     * domready (c) Dustin Diaz 2014 - License MIT
     * ie10 fix - Mikael Kristiansson 2019
     */
        t.exports = function () {
            var t = !1;
            -1 !== navigator.appVersion.indexOf("MSIE 10") && (t = !0);
            var e, n = [], i = "object" == typeof document && document, o = t ? i.documentElement.doScroll("left") : i.documentElement.doScroll, r = i && (o ? /^loaded|^c/ : /^loaded|^i|^c/).test(i.readyState);
            return !r && i && i.addEventListener("DOMContentLoaded", e = function () {
                for (i.removeEventListener("DOMContentLoaded", e),
                    r = 1; e = n.shift();)
                    e()
            }
            ),
                function (t) {
                    r ? setTimeout(t, 0) : n.push(t)
                }
        }()
    }
]);
/**
 * Minified by jsDelivr using Terser v3.14.1.
 * Original file: /npm/js-cookie@2.2.1/src/js.cookie.js
 * 
 * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files
 */
!function(e){var n;if("function"==typeof define&&define.amd&&(define(e),n=!0),"object"==typeof exports&&(module.exports=e(),n=!0),!n){var t=window.Cookies,o=window.Cookies=e();o.noConflict=function(){return window.Cookies=t,o}}}(function(){function e(){for(var e=0,n={};e<arguments.length;e++){var t=arguments[e];for(var o in t)n[o]=t[o]}return n}function n(e){return e.replace(/(%[0-9A-Z]{2})+/g,decodeURIComponent)}return function t(o){function r(){}function i(n,t,i){if("undefined"!=typeof document){"number"==typeof(i=e({path:"/"},r.defaults,i)).expires&&(i.expires=new Date(1*new Date+864e5*i.expires)),i.expires=i.expires?i.expires.toUTCString():"";try{var c=JSON.stringify(t);/^[\{\[]/.test(c)&&(t=c)}catch(e){}t=o.write?o.write(t,n):encodeURIComponent(String(t)).replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g,decodeURIComponent),n=encodeURIComponent(String(n)).replace(/%(23|24|26|2B|5E|60|7C)/g,decodeURIComponent).replace(/[\(\)]/g,escape);var f="";for(var u in i)i[u]&&(f+="; "+u,!0!==i[u]&&(f+="="+i[u].split(";")[0]));return document.cookie=n+"="+t+f}}function c(e,t){if("undefined"!=typeof document){for(var r={},i=document.cookie?document.cookie.split("; "):[],c=0;c<i.length;c++){var f=i[c].split("="),u=f.slice(1).join("=");t||'"'!==u.charAt(0)||(u=u.slice(1,-1));try{var a=n(f[0]);if(u=(o.read||o)(u,a)||n(u),t)try{u=JSON.parse(u)}catch(e){}if(r[a]=u,e===a)break}catch(e){}}return e?r[e]:r}}return r.set=i,r.get=function(e){return c(e,!1)},r.getJSON=function(e){return c(e,!0)},r.remove=function(n,t){i(n,"",e(t,{expires:-1}))},r.defaults={},r.withConverter=t,r}(function(){})});

var url = 'http://localhost:9000/initvisit';
var d = {
    url: location.href,
    referer: document.referrer,
    searchengine: '',
    searchkw: '',
    channelId: 0,
    uid:Cookies.get('uid')
}
installedModules[2].exports.post(url, d)
.then(d=>{
    d = JSON.parse(d);
    console.log(d);
    Cookies.set("uid",d.uid,{expires:365,path:'/'});
});